package com.usian.controller;

import com.usian.User;
import com.usian.feign.SentinelFeign;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RequestMapping("/user")
@RestController
public class UserController {

    @Autowired
    private SentinelFeign sentinelFeign;

    @RequestMapping(value = "/feign/findUserById")
    public User findUserById(Integer id){
        return sentinelFeign.findUserById(id);
    }

}
